<template>
  <div class="dark_table" style="width: 100%">
    <el-table
      v-adaptive
      :data="tableData"
      style="width: 100%"
      border
      height="100px"
      size="mini"
    >
      <el-table-column
        prop="manufactureSite"
        label="制造单元"
        align="center"
        show-overflow-tooltip
      >
        <template slot-scope="scope">
          {{ scope.row.manufactureSite || "-" }}
        </template>
      </el-table-column>
      <el-table-column
        prop="deviceName"
        label="设备名称"
        align="center"
        show-overflow-tooltip
      >
        <template slot-scope="scope">
          {{ scope.row.deviceName || "-" }}
        </template>
      </el-table-column>
      <el-table-column
        prop="deviceToken"
        label="设备编号"
        align="center"
        show-overflow-tooltip
      >
        <template slot-scope="scope">
          {{ scope.row.deviceToken || "-" }}
        </template>
      </el-table-column>
      <el-table-column
        prop="alarmTag"
        label="报警点位"
        align="center"
        show-overflow-tooltip
      >
        <template slot-scope="scope">
          {{ scope.row.alarmTag || "-" }}
        </template>
      </el-table-column>
      <el-table-column
        prop="alarmNo"
        label="报警号"
        align="center"
        show-overflow-tooltip
      >
        <template slot-scope="scope">
          {{ scope.row.alarmNo || "-" }}
        </template>
      </el-table-column>
      <el-table-column
        prop="message"
        label="报警描述"
        align="center"
        show-overflow-tooltip
      >
        <template slot-scope="scope">
          {{ scope.row.message || "-" }}
        </template>
      </el-table-column>
      <el-table-column
        prop="type"
        label="报警类型"
        align="center"
        show-overflow-tooltip
      >
        <template slot-scope="scope">
          {{ scope.row.type || "-" }}
        </template>
      </el-table-column>
      <el-table-column
        show-overflow-tooltip
        prop="alarmStartTime"
        label="开始时间"
        width="120"
        align="center"
      >
        <template slot-scope="scope">
          {{ scope.row.alarmStartTime | formatDate }}
        </template>
      </el-table-column>
      <el-table-column
        show-overflow-tooltip
        prop="alarmEndTime"
        label="结束时间"
        align="center"
        width="120"
      >
        <template slot-scope="scope">
          {{ scope.row.alarmEndTime | formatDate }}
        </template>
      </el-table-column>
    </el-table>
  </div>
</template>

<script>
export default {
  props: {
    tableData: {
      type: Array,
      default: () => []
    }
  },
  data() {
    return {};
  },
  methods: {}
};
</script>

<style lang="scss" scoped></style>
